﻿<UserControl x:Class="HomeModule.Shell.ShellView"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"
    xmlns:cal="clr-namespace:Microsoft.Practices.Composite.Presentation.Regions;assembly=Microsoft.Practices.Composite.Presentation" xmlns:Controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit" xmlns:Controls3="clr-namespace:PrismNavigationFramework.Navigation.Controls;assembly=PrismNavigationFramework" d:DesignHeight="500" d:DesignWidth="800">
    <UserControl.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="/StylesLibrary;component/Styles.xaml" />
                <ResourceDictionary Source="/StylesLibrary;component/TransitionFrameAnimations.xaml" />                
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </UserControl.Resources>
    <Controls:BusyIndicator IsBusy="{Binding WeAreLoadingModule}" BusyContent="Loading module... Please wait...">
        <Grid x:Name="LayoutRoot" Style="{StaticResource LayoutRootGridStyle}" MinWidth="800" MinHeight="600">
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>        
            <RowDefinition Height="*"/>            
        </Grid.RowDefinitions>
        
            <Border Grid.Row="1" x:Name="ContentBorder" Style="{StaticResource ContentBorderStyle}">
            <Grid>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="*"></ColumnDefinition>
                    <ColumnDefinition Width="Auto"></ColumnDefinition>                    
                    
                </Grid.ColumnDefinitions>
                    <Controls3:PrismNavigationMainFrame Style="{StaticResource CrissCrossSlideWithFadeInAnimationStyle}" Grid.Column="0" cal:RegionManager.RegionName="MainRegion" HorizontalAlignment="Center" VerticalAlignment="Center" >
                        
                    </Controls3:PrismNavigationMainFrame>

                    <Grid Grid.Column="1"  HorizontalAlignment="Center" VerticalAlignment="Center">
                    <StackPanel Orientation="Vertical">
                        <TextBlock Text="Available Widgets:" VerticalAlignment="Center" HorizontalAlignment="Center"></TextBlock>

                            <Controls3:PrismNavigationSecondaryFrame MaxHeight="400" cal:RegionManager.RegionName="WidgetsRegion" >
                                    <ItemsControl.Template>
                                        <ControlTemplate>
                                            <ScrollViewer x:Name="ScrollViewer" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto">
                                                <ItemsPresenter />
                                            </ScrollViewer>
                                        </ControlTemplate>
                                    </ItemsControl.Template>
                            </Controls3:PrismNavigationSecondaryFrame>
                    </StackPanel>
                </Grid>                    
                
            </Grid>                
        </Border>

        <Grid x:Name="NavigationGrid" Style="{StaticResource NavigationGridStyle}">

            <Border x:Name="BrandingBorder" Style="{StaticResource BrandingBorderStyle}">
                    <StackPanel Orientation="Vertical">
                        <StackPanel x:Name="BrandingStackPanel" Orientation="Horizontal" Style="{StaticResource BrandingStackPanelStyle}">

                    <ContentControl Style="{StaticResource LogoIcon}"/>
                    <TextBlock x:Name="ApplicationNameTextBlock" Style="{StaticResource ApplicationNameStyle}" 
                               Text="Prism Navigation Framework Sample MVVM Application"/>


                    </StackPanel>
                        <HyperlinkButton Content="Prism Navigation Framework" NavigateUri="http://prismnavigation.codeplex.com/" TargetName="_blank" />
                    </StackPanel>                        
            </Border>

            <Border x:Name="LinksBorder" Style="{StaticResource LinksBorderStyle}">
                <StackPanel Orientation="Vertical">
                <StackPanel x:Name="LinksStackPanel" Style="{StaticResource LinksStackPanelStyle}">

                    <HyperlinkButton x:Name="Link1" Style="{StaticResource LinkStyle}" 
                                     NavigateUri="/Home/Index" TargetName="MainRegion" Content="Home"/>

                    <Rectangle x:Name="Divider1" Style="{StaticResource DividerStyle}"/>

                    <HyperlinkButton x:Name="Link2" Style="{StaticResource LinkStyle}" 
                                     NavigateUri="/Home/About" TargetName="MainRegion" Content="About"/>

                    <Rectangle  Style="{StaticResource DividerStyle}"/>

                    <HyperlinkButton Style="{StaticResource LinkStyle}" 
                                     NavigateUri="/Facebook/UserDetails" TargetName="MainRegion" Content="Deffered Load of View from Facebook Module"/>

                </StackPanel>

                    <StackPanel  Style="{StaticResource LinksStackPanelStyle}">

                        <HyperlinkButton  Style="{StaticResource LinkStyle}" 
                                     NavigateUri="/Home/Index/UserId/1234" TargetName="MainRegion" Content="Home View With Parameters"/>

                        <Rectangle  Style="{StaticResource DividerStyle}"/>

                        <HyperlinkButton  Style="{StaticResource LinkStyle}" 
                                     NavigateUri="/Home/About/ParameterA/Some%20Text/ParameterB/12234" TargetName="MainRegion" Content="About  View With Parameters"/>

                        <Rectangle  Style="{StaticResource DividerStyle}"/>

                       
                    </StackPanel>

                </StackPanel>                    
            </Border>

        </Grid>

    </Grid>
    </Controls:BusyIndicator>        
</UserControl>
